package com.ruoyi.paper.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.paper.mapper.ExamLibMapper;
import com.ruoyi.paper.domain.ExamLib;
import com.ruoyi.paper.service.IExamLibService;
import com.ruoyi.common.core.text.Convert;

/**
 * 实训试题库Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-04-14
 */
@Service
public class ExamLibServiceImpl implements IExamLibService 
{
    @Autowired
    private ExamLibMapper examLibMapper;

    /**
     * 查询实训试题库
     * 
     * @param examLibId 实训试题库主键
     * @return 实训试题库
     */
    @Override
    public ExamLib selectExamLibByExamLibId(String examLibId)
    {
        return examLibMapper.selectExamLibByExamLibId(examLibId);
    }

    /**
     * 查询实训试题库列表
     * 
     * @param examLib 实训试题库
     * @return 实训试题库
     */
    @Override
    public List<ExamLib> selectExamLibList(ExamLib examLib)
    {
        return examLibMapper.selectExamLibList(examLib);
    }

    /**
     * 新增实训试题库
     * 
     * @param examLib 实训试题库
     * @return 结果
     */
    @Override
    public int insertExamLib(ExamLib examLib)
    {
        return examLibMapper.insertExamLib(examLib);
    }

    /**
     * 修改实训试题库
     * 
     * @param examLib 实训试题库
     * @return 结果
     */
    @Override
    public int updateExamLib(ExamLib examLib)
    {
        return examLibMapper.updateExamLib(examLib);
    }

    /**
     * 批量删除实训试题库
     * 
     * @param examLibIds 需要删除的实训试题库主键
     * @return 结果
     */
    @Override
    public int deleteExamLibByExamLibIds(String examLibIds)
    {
        return examLibMapper.deleteExamLibByExamLibIds(Convert.toStrArray(examLibIds));
    }

    /**
     * 删除实训试题库信息
     * 
     * @param examLibId 实训试题库主键
     * @return 结果
     */
    @Override
    public int deleteExamLibByExamLibId(String examLibId)
    {
        return examLibMapper.deleteExamLibByExamLibId(examLibId);
    }
}
